Deep reinforcement learning for air handling control

ABSTRACT

An engine system includes an air handling control unit which controls a plurality of air handling actuators responsible for maintaining flow of air and exhaust gas within the engine system. The engine system has a plurality of sensors whose sensor signals at least partially define a current state of the engine system. The air handling control unit includes a controller which controls the air handling actuators of the engine system as well as a processing unit coupled to the sensors and the controller. The processing unit includes an agent which learns a policy function that is trained to process the current state, determines a control signal to send to the controller by using the policy function after receiving the current state as an input, and outputs the control signal to the controller. Then, the agent receives a next state and a reward value from the processing unit and updates the policy function using a policy evaluation algorithm and a policy improvement algorithm based on the received reward value. Subsequently, the controller controls the air handling actuators in response to receiving the control signal. In one aspect of the embodiment, the control signal is a command signal for the air handling actuators.

FIELD OF THE DISCLOSURE

This disclosure relates generally to air handling systems for engines, and more specifically to systems with real-time self-learning air handling controls.

BACKGROUND OF THE DISCLOSURE

Recently, there has been an increased demand for engine systems with internal combustion engines to meet criteria such as improved fuel economy and reduced emissions, all the while maintaining optimal performance for the user, which led to the development of technologies such as fuel injection systems, turbocharging, and exhaust gas recirculation that made the engines much more environmentally-friendly without sacrificing satisfactory user experience. As a result, more emphasis is placed on the optimization of multiple criteria, which includes balancing fuel economy, emissions, and engine performance to achieve as much as possible in all criteria at the same time, by controlling variables within the engine system in a stochastic environment, a process generally referred to as engine tuning.

Specifically, it is desirable to control an air handling system of an internal combustion engine, particularly during transient events, to provide for a responsive air handling system capable of responding appropriately to transient operating conditions. As such, the internal combustion engine, which uses a turbocharger and an exhaust gas recirculation (EGR) system to control the air flow inside the cylinder, requires efficient engine tuning to fully utilize the available components and achieve optimal performance.

Prior art techniques of engine tuning include model-based air handling controllers which employ model predictive controllers (MPC). A block diagram of such MPC system is illustrated in FIG. 1, which is largely divided into a MPC block 1 and a process block 2. The system uses a process model 3 (which acts parallel to the process 2), a prediction block 4, a set-point calculations block 5, and a control calculations block 6 to predict the current process outputs. The residuals, which are the difference between the predicted model outputs and the actual process outputs, are fed back into the prediction block 4, along with the inputs from the control calculations block 6 which receives the predicted outputs from the prediction block 4 and set points (targets) from the set-point calculations block 5 to determine the actual inputs to enter into the process 2. Thus, the system uses residuals to correct its future predictions such that adjustments are made to more closely match the process model 3 with the process 2. As such, the accuracy of the initial model used in the process model 3 is very important, since the computations depend heavily on how accurate the model 3 is with respect to the performance of the actual process 2. Also, MPC typically incorporates linear functions to imitate the actual process that is dynamic in nature. Therefore, attempting to approximate dynamic models as linear functions may not capture the actual behavior of the process, thereby leading to poor performance by the system. Furthermore, linear models may be able to predict the current outputs within a finite time-horizon, but tend to be computationally expensive for high dimensional problem solved over longer time-horizon. Even if nonlinear models are incorporated to approximate the dynamic models, MPC would result in determining a local optimal solution which may not be the best solution, i.e. the global optimal solution. Also, MPC is computationally expensive and therefore cannot be implemented in engine control units.

Other prior art techniques include for example engine mapping. This technique conducts a series of tests on the engine and the program which controls it, and implements steady-state engine response as control variables to determine the inputs to the engine, which establishes the operating limits of the engine and sets control input bias with respect to the operating point, known as a steady-state calibration. Then, these input settings are graphically represented in the form of a characteristic map, which shows the performance curves that represent performance of the engine when there is a change in certain parameters such as speed, load, air-fuel ratio, as well as engine/ambient temperature. Most of the calibration techniques utilized rely on a person to perform off-line calibration and optimization and subsequently plug in values in the engine control module (ECM) for engine operation. These techniques apply post-processing to data collected in a controlled environment for calibration and optimization. However, off-line calibration requires a lot of statistics and data to prepare the engine for actual use, during which the engine will likely encounter situations and states that are not covered by the initial static dataset used for off-line calibration. As such, because real operating conditions can be drastically different from the conditions during calibration, such techniques are not adequate in adapting the engine to real conditions as it operates. Similar maps are designed for transient states that are tuned via trial-and-error processes where the calibrator runs different duty cycles and calibrate to meet the expected performance. Because it is not possible to run all the duty cycles in practice, such processes may lead to suboptimal performance for some cycles. Furthermore, because the calibration techniques are performed to model the engine behavior only in steady state, during the transient state the engine is controlled to meet a specific objective such as smoke or torque response, and thus other variables such as fuel consumption are typically given less weight when considering such factors during engine operation.

Therefore, there is a need to provide a more computationally efficient, real-time engine tuning technique which allows for a more accurate prediction of the actual engine behavior in a dynamic style to enable optimization of the air handling control within the engine, all the while reducing the dependency on the accuracy of the initial prediction model and frequent calibrations.

SUMMARY OF THE DISCLOSURE

Various embodiments of the present disclosure relate to a deep reinforcement learning for air handling control of an engine system, particularly to an internal combustion engine system. In one embodiment, the engine system includes an air handling control unit which controls a plurality of air handling actuators responsible for maintaining air and exhaust gas flow within the engine system. The engine system has a plurality of sensors coupled to it such that the sensor signals from these sensors at least partially define a current state of the engine system. The air handling control unit includes a controller which controls the air handling actuators of the engine system as well as a processing unit coupled to the sensors and the controller. The processing unit includes an agent which learns a policy function that is trained to process the current state, determines a control signal to send to the controller by using the policy function after receiving the current state as an input, and outputs the control signal to the controller. Then, the agent receives a next state and a reward value from the processing unit and updates the policy function using a policy evaluation algorithm and a policy improvement algorithm based on the received reward value. Subsequently, the controller controls the air handling actuators in response to receiving the control signal. In one aspect of the embodiment, the control signal is a command signal for the air handling actuators.

For example, the current state can be defined by one or more of the following parameters: speed value, load value or torque demand of the engine, and air handling states of the engine system. In another example, the current state can also have past values of these parameters, such as the speed value at a previous time step, the load value at a previous time step, and so on. Also, the air handling states can be determined by charge flow value and exhaust gas recirculation (EGR) fraction value. Also, the current state includes one or more of the following commands: charge flow command, EGR fraction commands, EGR flow commands, fresh air flow command, and intake manifold pressure command. Reward values are a weighted summation of the tracking accuracy, overshoot, and response time for EGR and charge flows in the engine.

In some embodiments, the agent is made of a plurality of function approximators. The function approximators used in these cases can be deep neural networks (DNN), support vector machines (SVM), regression-based methods, and decision trees. Also, DNN can include long short-term memory (LSTM) networks and convolution neural networks. Furthermore, the function approximators are trained to learn the initial policy function and improved using an optimization technique. Examples of such optimization technique are q-learning and policy gradients. Furthermore, in some embodiments, the function approximators imitate one or more preexisting air handling controllers using an imitation learning technique such as a dataset aggregation (DAGGER) algorithm.

While multiple embodiments are disclosed, still other embodiments of the present disclosure will become apparent to those skilled in the art from the following detailed description, which shows and describes illustrative embodiments of the disclosure. Accordingly, the drawings and detailed description are to be regarded as illustrative in nature and not restrictive.

BRIEF DESCRIPTION OF THE DRAWINGS

The embodiments will be more readily understood in view of the following description when accompanied by the below figures and wherein like reference numerals represent like elements. These depicted embodiments are to be understood as illustrative of the disclosure and not as limiting in any way.

FIG. 1 is a block diagram of a prior-art model predictive control system;

FIG. 2 is a block diagram of a general reinforcement learning technique as described herein;

FIG. 3 is a block diagram of an internal combustion engine system utilizing the reinforcement learning technique as described herein;

FIG. 4 is a block diagram of another internal combustion engine system utilizing the reinforcement learning technique as described herein;

FIG. 5 is a flow diagram of an algorithm for the reinforcement learning technique used with respect to the internal combustion engine system;

FIG. 6 is a flow diagram of a DAGGER algorithm implemented with respect to the engine system.

While the present disclosure is amenable to various modifications and alternative forms, specific embodiments have been shown by way of example in the drawings and are described in detail below. The intention, however, is not to limit the present disclosure to the particular embodiments described. On the contrary, the present disclosure is intended to cover all modifications, equivalents, and alternatives falling within the scope of the present disclosure as defined by the appended claims.

DETAILED DESCRIPTION OF THE DISCLOSURE

In the following detailed description, reference is made to the accompanying drawings which form a part hereof, and in which is shown by way of illustration specific embodiments in which the present disclosure is practiced. These embodiments are described in sufficient detail to enable those skilled in the art to practice the present disclosure, and it is to be understood that other embodiments can be utilized and that structural changes can be made without departing from the scope of the present disclosure. Therefore, the following detailed description is not to be taken in a limiting sense, and the scope of the present disclosure is defined by the appended claims and their equivalents.

Reference throughout this specification to “one embodiment,” “an embodiment,” or similar language means that a particular feature, structure, or characteristic described in connection with the embodiment is included in at least one embodiment of the present disclosure. Appearances of the phrases “in one embodiment,” “in an embodiment,” and similar language throughout this specification may, but do not necessarily, all refer to the same embodiment. Similarly, the use of the term “implementation” means an implementation having a particular feature, structure, or characteristic described in connection with one or more embodiments of the present disclosure, however, absent an express correlation to indicate otherwise, an implementation may be associated with one or more embodiments. Furthermore, the described features, structures, or characteristics of the subject matter described herein may be combined in any suitable manner in one or more embodiments.

FIG. 2 illustrates a high-level depiction of a basic reinforcement learning algorithm 200. Reinforcement learning is a machine learning technique which shares a structure similar to traditional control systems, hence well-suited towards control applications. There are two main components required for learning: an agent 202 and an environment 204. The agent 202 is a processing device such as a computing unit which has a memory to store instructions and other data necessary to perform the process, and the environment 204 is one or more components within the system which gives feedback to the agent 202 to allow the agent 202 to improve its prediction of the system's actual behavior. For example, the agent can be a deep learning neural model that takes states as an input and finds the actions as an output. Initially, the environment 204 sends a current state 206 of the environment 204 to the agent 202. In response, the agent 202 runs a set of rules known as a policy 208 which assists in determining what actions to take based on the current state. The policy can be a set of instructions stored in the memory of the deep learning neural model. As a result, the agent 202 outputs a current action 210 to the environment 204. The environment 204 then returns a next state 212 and a reward 214. The goal of the agent 202 is to find the policy 208 that maximizes the sum of the reward 214 over a time horizon. In other words, the agent 202 does not only consider the immediate reward received from the environment 204 as a result of the action 210 which caused the reward, but also future rewards which the agent 202 may receive in the long term, when determining the action 210. Details regarding this algorithm 200 will be further explained below in view of the engine systems illustrated in FIGS. 3 and 4.

FIG. 3 illustrates an embodiment of an internal combustion engine system 300 which includes an air handling control unit 302, an internal combustion engine 304, an exhaust gas recirculation (EGR) actuator 306, and a turbocharger 308. Additionally, EGR cooler 310 and intake cooler 312 each cools the air or exhaust gas passing through them before being received by the internal combustion engine 304. In the figure, bold lines indicate the flowpath of air and gases through the system, and the dashed lines indicate data signal transmitted via wires or wirelessly as appropriate between each component in the system. The engine 304 has an intake manifold 314 as well as an exhaust manifold 316. Although not shown in FIG. 3, the engine system can also include a fuel system which has a fuel tank, fuel supply pump, fuel filter, fuel heaters and coolers, and other components of a fuel injection system, as appropriate. The turbocharger 308 includes a compressor 318 and a turbine 320 connected with a rotatable shaft 322. The air handling control unit 302 includes a processing unit 324 and a controller 326. The flowpath begins at a fresh air inlet 328 where fresh air, also referred to as charge air, enters the system from the atmosphere, the movement of which is assisted by activating the compressor 318 which forces more air into the system. Then, the intake cooler 312 cools the air supplied by the compressor 318 and sends it to an intake air passageway 330 leading to the intake manifold 314 of the engine. Inside the internal combustion engine 304, fuel mixes with the inserted air and a sparkplug (not shown) causes a spark to create combustion within the engine to move the motor, if the engine 304 is a spark ignition engine. Otherwise, if the engine 304 is a compression ignition engine such as a diesel engine, for example, the heat and pressure created by the engine 304 during the compression process causes ignition of the engine. The exhaust gas leaves the exhaust manifold 316 through an exhaust gas passageway 332 to the EGR cooler 310 and the turbine 320. Exhaust gas reenters the engine through the intake manifold 314 when the EGR actuator 306 is enabled, and the exhaust gas drives the turbine 320 causing the shaft 322 to rotate and thereby causing the compressor 318 to force air into the system. As such, the EGR actuator 306 and the turbocharger 308 work together to increase the air flow into the intake manifold 314 and the speed of the engine. The leftover exhaust gas exits the system through an exhaust conduit 334.

Furthermore, the engine system 300 incorporates a high-pressure EGR system in which the EGR actuator 306 recirculates exhaust gas between the two high-pressure points, i.e. the exhaust manifold and the inlet manifold. In another embodiment shown in FIG. 4, a low-pressure EGR system is used for an internal combustion engine system 400, in which the EGR actuator 306 is positioned in a separate location such that it recirculates exhaust gas between the two low-pressure points, i.e. the exhaust conduit (also referred to as the exhaust tail pipe) and the turbocharger inlet. This engine system 400 does not require a separate cooler as it did in the engine system 300 because both the exhaust gas and the incoming air would pass through the same intake cooler 312. Furthermore, in another embodiment, the engine system can have more than one EGR actuator and turbocharger which can improve the air handling efficiency of the engine system.

Activation of the EGR actuator 306 and turbine 320 help to increase the speed of the engine, but they must be controlled to achieve optimal efficiency within the system. In other words, it is desirable for the engine to maintain some of these components in a deactivated state when there is no need for an increase in the speed of the engine, such as, if the engine system is incorporated into a car, when the user is driving on a road with a lower speed limit than a freeway or the driving style of the user indicates that he or she tends to drive at a more moderate speed. As such, a current state of the engine system may be used in determining whether such activation is necessary. In the reinforcement learning technique of FIG. 2, the current state of the system is determined by taking measurements in each component of the engine system using a plurality of sensors. For example, a set of sensors 336 coupled to the intake manifold 314, internal combustion engine 304, and the exhaust manifold 316 can measure engine parameters including but not limited to the inlet temperature, inlet flow rate, charge pressure, and engine speed. Sensors 338 coupled to the EGR actuator 306 can measure the differential pressure, or ΔP, across the actuator and the exhaust gas flow rate of the through the actuator. These are only examples of what parameters can be measured by the sensors; other conventional sensors can also be used as appropriate.

Measurements from the sensors 336 and 338 are sent as sensor signals 337 and 339, respectively, to the processing unit 324 which uses these data to determine the next actions to be taken by the controller 326. The processing unit 324 includes the agent 202 from FIG. 2 which performs this determination. In one example, the agent 202 is a plurality of function approximators which take in the data from the processing unit 324 as input and output a command signal 340 to the controller 326, where the process used by the function approximators can be any known machine learning architecture such as deep neural networks (DNN), support vector machines (SVM), regression-based methods (which includes logistic, lasso, ridge, etc.), and decision trees, as appropriate. The DNN can be long short-term memory (LSTM) networks or convolution neural networks, or other appropriate types of network or conventional networks known in the art.

The function approximators act to approximate how the engine behaves under different conditions using a reinforcement learning technique as explained in FIG. 2. For the internal combustion engine systems 300 and 400, the environment 204 can include the internal combustion engine 304, the EGR system 306, the turbocharger 308, or any other component which may affect the state of the environment.

In one example, the states of the internal combustion engine system can include one or more of: the engine speed, the engine load (torque output of the engine), torque demand for the engine, and the air handling states. The air handling states can include one or more of: the charge flow of the engine (the sum of air flow into the intake manifold of the engine) and the EGR fraction (the fraction of charge flow attributable to recirculated exhaust gas from the engine). Additionally, the air handling states can also include one or more of: prior EGR flow commands, fresh air flow command, and intake manifold pressure command as previously sent by the controller. Furthermore, although FIGS. 3 and 4 show engine systems with a high-pressure EGR system and a low-pressure EGR system, respectively, some embodiments can include both high- and low-pressure EGR configurations in one system, such that the exhaust gas has two opportunities to recirculate back into the engine system, which can further increase the efficiency of the engine.

FIG. 5 illustrates a flow diagram of a method 500 executed by the agent 202 to control the air handling actuators in the engine systems 300 and 400. Firstly, the agent learns a policy function trained to process a current state in step 502. Then, the agent determines the output control signal by using the policy function after receiving the current state as an input in step 504. The agent subsequently receives the next state and the next reward value from the environment in step 506, and updates the policy function using a policy evaluation algorithm and a policy improvement algorithm based on the reward value in step 508. In some examples, more than one such algorithm can be used to further improve the policy. Lastly, the agent controls air handling in response to the determined output control signal in step 510 by controlling the air handling actuators in the engine system.

A detailed explanation of the reinforcement learning technique is described below in view of the engine systems illustrated in FIGS. 3 and 4. Initially, the processing unit 324 receives the sensor signals 337 and 339 from the corresponding components in the engine system. Then, the processing unit 324 determines the current state of the engine system using an algorithm programmed into the processing unit. For example, in one embodiment, the processing unit 324 can process the raw sensor signal data and determine the relevant data which indicate a need for certain actions to take place, such as by comparing the sensor signal data values to predetermined threshold values, and send the processed data indicating the initial current state x₀ to the agent.

The agent 202 has a policy π which is the starting function for the learning technique. A policy π is a function which considers the current state x_(t) to output a corresponding action u_(t), expressed as u_(t)=π(x_(t)). As such, the policy π determines the initial action u₀ and sends a command signal 340 to the controller 326. The controller 326 then sends the appropriate command signals 342 and 344 to the EGR actuator 306 and the turbine 320, respectively, based on the command signal 340. The command signal 340 can include the target EGR value (such as how much of the exhaust gas should be recirculated back into the engine and how much pressure should be in the intake manifold), the target turbocharger value (such as a target boost value that the turbocharger needs to provide to the engine), and the target intake temperature (the temperature of the intake air such that the incoming air is not too hot for the engine). In one example, the turbocharger is a variable geometry turbocharger.

After the command signals are applied, the engine system (i.e. the environment) enters the next state, after which the sensors provide new measurements to the processing unit 324, which uses these updated sensor signals to calculate the new current state x₁ of the environment and sends the data to the agent 202, along with a first reward r₀ which is a scalar value. The processing unit 324 stores a program which calculates the reward, i.e. a reward function R such that r_(t)=R(u_(t), x_(t), x_(t+1)), to send to the agent 202. For example, the reward is a weighted summation of the tracking accuracy, overshoot, and response time of EGR flows and a charge flow as outputted by the engine system. Once the agent 202 receives the first reward r₀, the agent 202 determines the next action u₁ by using the policy π based on the current state x₁, i.e. u₁=π(x₁).

To evaluate the quality of the policy π, a value function V is calculated such that V(π(x _(N)))=Σ_(t=0) ^(N)(γ^(t) r _(t))  (1) for a time horizon from t=0 to t=N. When the N value approaches infinity (i.e. the system runs for a prolonged period of time) the value function V can represent a receding horizon problem, which is useful in understanding the global stability properties of any local optimization that is determined by the policy. In the function, γ is the discount factor between 0 and 1 which denotes how much weight is placed on future rewards in comparison with the immediate rewards. The discount factor γ is necessary to make the sum of rewards converge, and this denotes that future rewards are preferred at a discounted rate with respect to the immediate reward. The policy π must act in a way to increase as much reward gained as possible, therefore the goal of the agent 202 is to find a policy π that maximizes a sum of the reward over the time horizon, i.e. max Σ_(t=0) ^(N) (γ^(t)r_(t)).

The policy π is also constantly improved using policy evaluation and policy improvement algorithms. During a policy evaluation process, the value function V(π) is calculated for some, or all, of the states x based on a fixed policy π. Then, during a policy improvement process which follows, the policy π is improved by using the value function V(π) obtained in the policy evaluation step such that a value function V(7 e) calculated using the new policy π′ is greater than or equal to the value function V(π) calculated using the original policy π. These two processes are repeated one after another until either (a) the policy π remains unchanged, (b) the processes continue for more than a predetermined period of time, or (c) the change to the value function V is less than a predetermined threshold.

Numerous different approaches can be taken to achieve the goal of maximizing the sum of reward. Some of the approaches are model-based (an explicit model of the environment is estimated and an optimal policy is computed for the estimated model) and model-free (the optimal policy is learned without first learning an explicit model, such as value-function based learning that is related to the dynamic programming principles). One example of a model-free approach is an optimization technique known as “q-learning”. The q-learning technique develops and updates a map Q(x_(t), u_(t)) which is similar to a value function that gives an estimate sum of rewards r_(t) for a pair of a given state x_(t) and action u_(t). This map is initialized with a starting value and successively updated by observing the reward using an update function, as explained below. The map function is described by the following equation: Q(x _(t) ,u _(t))←(1−α)Q(x _(t) ,u _(t))+α(r _(t)+γmax_(u) Q(x _(t+1) ,u))  (2) where Q(x_(t),u_(t)) is the old value, α is a learning rate between 0 and 1, max_(u)Q(u, x_(t+1)) is the estimate of the optimal future value, and (r_(t)+γmax_(u)Q(x_(t+1),u)) is the learned value. As such, the old value is replaced by a new value, which is the old value transformed using the learning rate and the learned value as shown in the equation (2). The q-learning is an off-policy value-based learning technique, in which the value of the optimal policy is learned independently of the agent's actions chosen for the next state, in contrast to on-policy learning techniques like “policy gradient” which can also be used as a learning technique for the engine system as described herein. Advantages of q-learning technique includes being more successful at finding a global optimum solution rather than just a local maximum.

A policy gradient technique is a direct policy method which starts with learning a map from state to action, and adjusts weights of each action by using gradient descent with the feedback from the environment. For any expected return function J(θ), the policy gradient technique searches for a local maximum in J(θ) so the expected return function J(θ)=E{Σ _(k=0) ^(H) a _(k) r _(k)}  (3) is optimized where a_(k) denotes time-step dependent weighting factors often set to a_(k)=γ^(k) for discounted reinforcement learning, by ascending the gradient of the policy with respect to the parameter θ, i.e. Δθ=α∇_(θ) J(θ)  (4) where ∇_(θ)J(θ) is the policy gradient and a is a step-size parameter, the policy gradient being:

$\begin{matrix} {{\nabla_{\theta}{J(\theta)}} = {\begin{bmatrix} \frac{\partial{J(\theta)}}{\partial\theta_{1}} \\ \vdots \\ \frac{\partial{J(\theta)}}{\partial\theta_{n}} \end{bmatrix}.}} & (5) \end{matrix}$ The policy gradient can then be calculated or approximated using methods such as finite difference methods and likelihood ratio methods. As such, the policy gradient technique guarantees that the system will converge to reach a local maximum for the expected returns. Furthermore, other model-free algorithms, such as SARSA (state-action-reward-state-action) algorithm, deep Q network (DQN) algorithm, deep deterministic policy gradient (DDPG) algorithm, trust region policy optimization (TRPO) algorithm, and proximal policy optimization (PPO) algorithm, can also be used.

In another example, a neural network model that is initially trained to imitate a known engine control can be used to achieve the goal of maximizing the sum of reward such that the model and the reward function is provided in which the objective is to identify the best policy for the system. One approach to train the model is by using imitation learning, which imitates an expert (or teacher) that provides a set of demonstration trajectories, which are sequences of states and actions. As such, the agent (or learner) needs to determine a policy whose resulting state/action trajectory distribution matches that of the expert. One example of imitation learning is “data aggregation”, also abbreviated as DAGGER, algorithm. The process of the DAGGER algorithm is explained in the below steps:

-   -   (1) The expert performs a certain task (action) and data is         collected (observation) as an expert dataset (D_(π*));     -   (2) A base policy (model) is created which maps the observations         to actions, with the observations as inputs and actions as         output;     -   (3) Tasks are performed using the base policy, and new dataset         (D_(π)) is collected for observation;     -   (4) An automated expert (e.g. an existing air handling         controller) labels the observed dataset (D_(π)) collected in         step 3 with the appropriate actions (u_(t));     -   (5) The observed dataset (D_(π)) is aggregated with the expert         dataset (D_(π*)) to become the new expert dataset (D_(π*)) so         that the expert dataset (D_(π*)) contains the actions (u_(t))         newly labeled by the expert;     -   (6) The policy is trained again with the new observations and         labeled (action) pair collected in step 4; and     -   (7) Steps 3 to 6 are repeated until the error between the human         expert and the policy model is minimized to at or below a         satisfactory threshold.         In view of the above, as the number of iterations are increased,         the target value generated by the policy trained with imitation         learning improves over time.

FIG. 6 illustrates one example of how the DAGGER algorithm can be implemented. In step 602, the expert, which in this case can be any known engine controller, runs a speed/load trajectory. In step 604, observations (o_(t)) and the actions (u_(t)) are collected to be used in training a machine learning classifier, which can be one or more function approximator, using supervised learning in step 606. Then, a base policy π_(θ)(u_(t)|o_(t)) is obtained such that the policy indicates which action u_(t) to take in view of a given observation o_(t) in step 608. In step 610, the machine learning classifier runs a different speed/load trajectory with the base policy π_(θ)(u_(t)|o_(t)). The observations o_(t) are collected again in step 612 after which the expert is asked to label the observations o_(t) in step 614. Then, the actions (u_(t)) are collected in step 616 to be used in training the machine learning classifier in step 618. The policy is subsequently updated in step 620, and the process returns to having the machine learning classifier run other different speed/load trajectory with the base policy in step 610. In this example, the observations can include one or more of: engine speed, torque demand, actual charge flow value, actual EGR value, and actual NO_(x) value of the engine. Also, the actions can include one or more of: target charge flow value and target EGR value, among others. As the number of iterations are increased, the policy trained with the imitation learning improves to more closely imitate the expert.

Because reinforcement learning shares a structure similar to a traditional control system, advantages of using such a technique includes the ability to capture non-linearity of the model to a high precision, resulting in improved performance. Current calibration techniques model engine behaviors in steady state and involve having technicians perform the calibration and optimization off-line and plug in the values for engine operation. Reinforcement learning can reduce such a calibration effort because the reinforcement learning technique can optimally meet all performance indexes for the engine system. Furthermore, the reinforcement learning utilizes on-line optimization with data collected in real conditions (such as when the engine is in operation) to calibrate and optimize the parameters within the engine, which allows the engine to adapt to changes in the operating condition without needing to recalibrate. As such, due to the adaptive nature of the reinforcement learning technique, even when the engine is running in a non-calibrated condition, the engine can learn or calibrate relevant parameters on its own to deliver similar levels of performance.

Furthermore, the aforementioned air handling control can be used for other types of engines besides the internal combustion engines as described above. For example, the engine of a plug-in hybrid electric vehicles combines a gasoline or diesel engine with an electric motor with a rechargeable battery, such that the battery initially drives the car and the conventional engine takes over when the battery runs out. In such an instance, the air handling control can be programmed to activate after the vehicle switches its power source from the battery to the conventional engine. Also, electric vehicles which uses only electric motors or traction motors for propulsion can include such air handling controls. In this case, the air handling control can be replaced by a climate control system for the interior of the car, such as a power heating and air conditioning system, for example.

The present subject matter may be embodied in other specific forms without departing from the scope of the present disclosure. The described embodiments are to be considered in all respects only as illustrative and not restrictive. Those skilled in the art will recognize that other implementations consistent with the disclosed embodiments are possible. 

What is claimed is:
 1. An air handling control for an engine system, comprising: a plurality of sensors coupled to the engine system, wherein sensor signals from the plurality of sensors at least partially define a current state of the engine system; a plurality of air handling actuators; a controller operable to control the air handling actuators; a processing unit coupled to the sensors and the controller; and the processing unit is operative to: determine, by using a policy function initially obtained using at least one function approximator trained with an imitation learning technique and configured to receive the current state as an input, a control signal configured to maximize a sum of reward values over a time horizon, output the control signal to the controller, receive a next state and a reward value from the processing unit, perform a policy evaluation algorithm and a policy improvement algorithm using the reward value, and update the policy function based on a result of the performed policy evaluation and improvement algorithms, wherein the controller controls the air handling actuators in response to the control signal.
 2. The air handling control of claim 1, wherein the current states comprise one or more of: a speed value, a load value, and air handling states of the engine system.
 3. The air handling control of claim 1, wherein the control signal is a command signal for the air handling actuators.
 4. The air handling control of claim 1, wherein the reward value comprises a weighted summation of tracking accuracy, overshoot, and response time for emission gas recirculation (EGR) flows and a charge flow.
 5. The air handling control of claim 1, wherein the at least one function approximator comprises one or more of: deep neural networks, support vector machines (SVM), regression based methods, and decision trees.
 6. The air handling control of claim 5, wherein the deep neural networks comprise one or more of: long short-term memory (LSTM) networks and convolution neural networks.
 7. The air handling control of claim 5, wherein the deep neural networks are improved using an optimization technique comprising one or more of: q-learning and policy gradient.
 8. The air handling control of claim 7, wherein the at least one function approximators imitates one or more preexisting air handling controllers.
 9. The air handling control of claim 8, wherein the at least one function approximators uses an imitation learning technique comprising a dataset aggregation (DAGGER) algorithm.
 10. A method in a non-transitory computer-readable medium for controlling air handling of an engine system, comprising: determining, by a processing unit, a current state of the engine system based at least partially on sensor signals; determining, by the processing unit, an output control signal by using a policy function initially obtained using at least one function approximator trained with an imitation learning technique and configured to receive the current state as an input, the control signal configured to maximize a sum of reward values over a time horizon; receiving, by the processing unit, a next state and a reward value; performing, by the processing unit, a policy evaluation algorithm and a policy improvement algorithm based on the reward value; updating the policy function, by the processing unit; and controlling, by a controller operatively coupled to the processing unit, air handling of the engine system in response to the determined output control signal.
 11. The method of claim 10, wherein the current state comprises one or more of: a speed value, a load value, and air handling states, and air handling commands, the air handling commands comprising one or more of: exhaust gas recirculation (EGR) flow commands and a charge flow command of the engine system.
 12. The method of claim 10, wherein the output control signal is an air handling actuator command signal.
 13. The method of claim 10, wherein the reward value comprises approximate functions of tracking accuracy, overshoot, and response time of EGR flows and a charge flow.
 14. The method of claim 10, wherein the at least one function approximator comprises one or more of: deep neural networks, support vector machines (SVM), regression based models, and decision trees.
 15. The method of claim 14, wherein the deep neural networks comprise one or more of: long short-term memory (LSTM) networks and convolution neural networks.
 16. The method of claim 14, wherein the deep neural networks are improved using an optimization technique comprising one or more of: q-learning and policy gradient.
 17. The method of claim 16, wherein the at least one function approximators imitates one or more preexisting air handling controllers.
 18. The method of claim 17, wherein the imitation learning technique comprises a dataset aggregation (DAGGER) algorithm.
 19. An internal combustion engine system, comprising: an internal combustion engine; at least one exhaust gas recirculation (EGR) actuator; at least one turbocharger; a plurality of sensors coupled to the at least one exhaust gas recirculation actuator and the internal combustion engine, wherein sensor signals from the plurality of sensors at least partially define a current state; a controller operable to control the at least one exhaust gas recirculation actuator and the at least one turbocharger; and a processing unit coupled to the sensors and the controller, the processing unit comprising a plurality of function approximators operative to interact with the engine system to: determine, by a policy function initially obtained using the plurality of function approximators trained with an imitation learning technique and configured to receive the current state as an input, an air handling actuator command signal configured to maximize a sum of reward values over a time horizon, output the air handling actuator command signal to the controller, receive a next state and a reward value from the processing unit, perform a policy evaluation algorithm and a policy improvement algorithm using the reward value, and update the policy function based on a result of the performed policy evaluation and improvement algorithms, wherein the function approximators are trained with an imitation learning technique to learn the initial policy function and the function approximators are improved using an optimization technique, and wherein the controller controls the exhaust gas recirculation actuator and the turbocharger in response to the control signal.
 20. The internal combustion engine system of claim 19, wherein: the current state comprises one or more of: a speed value, a load value, and air handling states of the engine system, the control signal is a command signal for the at least one EGR actuator, and the reward value comprises a weighted summation of one or more of: tracking accuracy, overshoot, and response time of EGR flows and a charge flow. 